home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Floppyshop 2
/
Floppyshop - 2.zip
/
Floppyshop - 2.iso
/
diskmags
/
0022-3.564
/
dmg-3413
/
news.txt
/
stos3.asc
< prev
next >
Wrap
Text File
|
1989-04-05
|
7KB
|
139 lines
**************************************
* *
* STOS BASIC TUTORIAL - PART THREE *
* ¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯ *
* *
* Written by Lozian for STEN *
* ¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯ *
**************************************
Screens drawn with Degas or Degas Elite and saved in Low Resolution are
given a PI1 extender. Screens saved in Medium Resolution are given a
PI2 extender. Screens saved in compressed format from Degas or Degas
Elite will not work with STOS. These screens can be identified by the
extender PC1 or PC2. Screens saved from the Neochrome art package are
given a NEO extender.
Plenty of screens exist in the Public Domain in the PI1 format,the PI2
format and the NEO format,or you can design your own.Other art packages
can be used for drawing and some of them have conversion programs to
convert the screen from the format the package uses to a PI1,PI2 format
or NEO.
Manipulation of your chosen screen rests entirely with what you have
on the screen. You can cut a desired part and zoom it to fill the
screen,or you can change the colours or maybe scroll vertically or
horizontally, all from within STOS.
To load your screen to STOS, you must first of all reserve some memory
for it. Enter as a Direct Command i.e. RESERVE AS DATASCREEN 5. This
will reserve bank number 5 as a PERMANENT bank of memory to load your
screen into. The difference between Temporary and Permanent banks is
that Permanent banks and what they contain are saved out when you save
a STOS.BAS program. A Temporary bank's contents are lost when you
subsequently save out your program as a BAS file and anything that you
required in that bank would have to be reloaded from disc.
To load a screen into STOS the following procedure should be adopted.
Direct Command (If not already done) - RESERVE AS DATASCREEN 5. VERY
IMPORTANT you do not put this command in the program. It will throw up
an error every time it is accessed.( BANK 5 ALREADY RESERVED ).
32K is now reserved for your screen.
Direct Command - HEXA OFF:LISTBANK ( To view what you have reserved ),
or use the mouse to point at the key bar and click.
Key in the following program and insert your COPY of STOS.
5 CLS:KEY OFF:MODE 0:FLASH OFF:HIDE:CURS OFF
10 BACK=LOGIC
15 LOAD "\STOS\PIC.PI1",5:REM Picture in STOS folder OR choose your own,
or load a NEO by changing extender to .NEO.
20 GET PALETTE (5):REM Gets the correct colours for screen in BANK 5.
25 APPEAR 5,15:REM Change the 15 to your choice and view the results.
30 WAIT 250
35 ZOOM 5,15,136,118,177 TO 0,0,319,199:REM Experiment with the
co-ordinates.
40 WAIT 250
45 ZOOM 5,45,96,269,119 TO 0,0,319,199
50 WAIT 250
55 ZOOM 5,200,140,290,171, TO 0,0,319,199
Save your program with a BAS extender and next time you load it you
won't have to RESERVE or load in the screen from disc.
An easy way to find the co-ordinates for the zoom boxes is to load in
from the accessory disc MOUSE.ACB. (Very handy accessory).
So Direct Commands ACCNEW:ACCLOAD "MOUSE.ACB" . Press HELP key to view
which function key to press (Should be F1) and press function key.
Accessory will now run and request type of picture to load. Remember
the PIC.PI1 is in a folder. Load picture and then move mouse. Mouse
sprite will now indicate posistion of X and Y co-ordinates and these
can be noted for use in the zoom function and other functions which
you can read about next time. Any program previously keyed in is still
in the memory and you can return to it after using the accessory.
To conserve memory,screens can be compacted with the accessory from
the disk COMPACT.ACB. Direct command ACCLOAD "COMPACT.ACB". If you
did not give the command ACCNEW (which removes all accessories),any
previously loaded accessories will still be available. So if you still
have the MOUSE.ACB available from function key F1,then COMPACT.ACB will
be allocated F2. To access COMPACT.ACB press HELP and then F2 or which-
ever function key it has been allocated to. Observe the screen after
pressing the HELP key.
The screen will clear and a Menu Bar will show various options. Load
your required screen and the accessory will compact it for you which
drastically cuts the memory it will occupy. You will be informed how
much memory you have saved. Next save the compacted screen to disk as
a file with a MBK extension. Compacting finished.
To load back your .MBK file just use the following procedure.
LOAD "SCREEN1.MBK",5:REM Loads compacted screen into BANK 5.
Then you can unpck the screen using the UNPACK command.
BACK=LOGIC:UNPACK 5,BACK:REM Unpacks the screen to appear as the back
screen and the logic screen together.
To use the full manipulation procedures of STOS I have found that a
compacted screen is not so easy to manipulate as an uncompacted one
but I will leave you to discover what can be done.
Please note that now you have compacted any screen it will require a
lot less memory and it makes sense to regain any memory reserved in
a bank for a screen,by the command CLEAR,and then proceed to load in
the COMPACTED screen as shown above. The COMPACTED screen that now
loads in,will occupy only the memory it requires. If a BANK is not
declared as in LOAD "SCREEN1.MBK",8 then BANK 5 will automatically
become the BANK containing the screen.
Also note that SPRITES use an MBK extender when they are saved,so try
to give your screens exclusive names e.g. SCREEN8,so that you can then
differeniate between SPRITES and SCREENS.
Experiment and have fun and next time we'll try moving the screen in
various directions.
COMING IN PART FOUR
-------------------
Srolling left,right,up and down. You name it,STOS can do it if you
have got the time and the patience, to wait for the next article.
Keep experimenting. Feedback appreciated.
(c) Lozian MCMXC11.
Banffshire.
~~~OOOO~~~